package io.renren.controller;

import io.renren.common.utils.PageUtils;
import io.renren.common.utils.R;
import io.renren.dto.GoodsInfoQueryDto;
import io.renren.service.ApiGoodsInfoService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author JinYang
 * @version 1.0
 * @belongsProject supermarket-management-system
 * @belongsPackage io.renren.controller
 * @createTime 2024-08-14  14:35
 * @description TODO
 */
@RestController
@RequestMapping("/api/goodsInfo")
@Api(tags="商品信息接口")
public class ApiGoodsInfoController {

    @Resource
    private ApiGoodsInfoService goodsInfoService;

    /**
     * 列表
     */
    @RequestMapping("/list")
    @ApiOperation("商品信息")
    public R list(GoodsInfoQueryDto goodsInfoQueryDto){
        PageUtils page = goodsInfoService.queryPage(goodsInfoQueryDto);

        return R.ok().put("page", page);
    }


}
